package org.apache.rocketmq.console.script.service.impl;

import org.apache.rocketmq.console.script.dao.RegionInfoDao;
import org.apache.rocketmq.console.script.model.RegionInfo;
import org.apache.rocketmq.console.script.service.RegionInfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class RegionInfoServiceImpl implements RegionInfoService {
	@Autowired
	private RegionInfoDao regionInfoDao;

	@Override
	public void save(RegionInfo entity) {
		regionInfoDao.save(entity);
	}

	@Override
	public RegionInfo findByRegionCode(String regionCode) {
		return regionInfoDao.findOneByCode(regionCode);
	}

}
